package gui;

import java.awt.GridLayout;

import javax.swing.JFrame;


public class TelaGrafico extends JFrame {
	
	PainelGrafico painelgrafico;

	GridLayout gridLayout1 = new GridLayout();

	public TelaGrafico(Grafico g) {
		super(g.tituloGrafico);
		painelgrafico = new PainelGrafico();
		painelgrafico.setPanielGrafico(g);
		try {
			jbInit();
		} catch (Exception e) {
			e.printStackTrace();
		}
	}

	private void jbInit() throws Exception {

		this.getContentPane().setLayout(gridLayout1);
		this.setLocale(java.util.Locale.getDefault());
		this.setSize(500, 500);
		gridLayout1.setColumns(1);
		this.getContentPane().add(painelgrafico);
		this.setDefaultCloseOperation(DISPOSE_ON_CLOSE);
		this.setVisible(true);
	}

}
